import fetch from 'common/src/utils/fetch';
export function queryPermissionsList (data = {}) {
  return fetch({
    url: '/api/textbookservice/permissionsManage/listPage',
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    data
  });
}
export function addPermissions (data) {
  return fetch({
    url: '/api/textbookservice/permissionsManage/add',
    method: 'POST',
    data
  });
}
export function updatePermissions (data) {
  return fetch({
    url: '/api/textbookservice/permissionsManage/update',
    method: 'PUT',
    data
  });
}
export function deletePermissions (id) {
  return fetch({
    url: `/api/textbookservice/permissionsManage/delete/${id}`,
    method: 'DELETE',
    headers: { 'Content-Type': 'application/json' },
  })
}
export function findPermissions (data = {}) {
  return fetch({
    url: '/api/textbookservice/permissionsManage/findOne',
    method: 'GET',
    headers: { 'Content-Type': 'application/json' },
    params: data
  })
}
